<template>
  <div>
    <div class="tabControl">
      <div class="control-item" v-for="(item,index) in tabControlList" :key="index">
        <p class="item" :class="{active:currentIndex===index}" @click="changeIndex(index)">{{ item }}</p>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  name: "TabNav"
}
</script>

<style scoped lang="css">
.tabControl-container{
  width: 100%;
  margin-top: 20px;
  /*margin-bottom: 52px;*/
  padding-bottom: 60px;
}
.tabControl{
  position: sticky;
  z-index: 9999999;
  top: 45px;
  /*width: 100%;*/
  display: flex;
  justify-content: space-between;
  padding: 8px;
  background-color: #fff;
}
.control-item{
  display: flex;
  font-size: 14px;
  flex: 1;
  text-align: center;
  justify-content: center;
  align-items: center;
}
.active{
  color: #42bBaa;
  border-bottom: 3px #42bBaa solid;
}
.item{
  /*height: 30px;*/
  width: 28px;
  height: 20px;
  padding: -3px;
  /*border-bottom: 2px #42bBaa solid;*/
}
</style>